<?php
defined('BASEPATH') OR exit('No direct script access allowed');
?>

    <div class="container">
      <div class="page-header">
        <div class="row">
          <div class="col-lg-9">
            <div class="row">
              <h4>Draft Board</h4>
              <ul class="nav nav-tabs">
                <li class="active"><a href="#totals-tbl" data-toggle="tab" aria-expanded="true">Totals</a></li>
                <li class=""><a href="#pergame-tbl" data-toggle="tab" aria-expanded="false">Per Game</a></li>
                <li class=""><a href="#projections-tbl" data-toggle="tab" aria-expanded="false">Projections</a></li>
                <li class=""><a href="#cat-tbl" data-toggle="tab" aria-expanded="false">Cat Analysis</a></li>

                <form class="navbar-form navbar-right" role="search">
                  <select class="form-control draft-search" id="select">
                    <option value="All">All</option>
                    <option value="PG">PG</option>
                    <option value="SG">SG</option>
                    <option value="SF">SF</option>
                    <option value="PF">PF</option>
                    <option value="C">C</option>
                  </select>
                  <input type="text" class="form-control draft-search" placeholder="Search">
                </form>
              </ul>

              <!-- Totals -->
              <div class="tab-content">
              <div class="tab-pane fade active in" id="totals-tbl">
              <table class="table table-hover">
                <thead class="tbl-header">
                  <tr>
                  	<th class='rank-cell'>Y!</th>
					<th class='rank-cell'>E</th>
					<th class='rank-cell'>RZ</th>
					<th class='name-cell'>NAME</th>
					<th class='stats-cell'>GMS</th>
					<th class='stats-cell'>MIN</th>
					<th class='stats-cell'>FG%</th>
					<th class='stats-cell'>FT%</th>
					<th class='stats-cell'>3PM</th>
					<th class='stats-cell'>PTS</th>
					<th class='stats-cell'>REB</th>
					<th class='stats-cell'>AST</th>
					<th class='stats-cell'>STL</th>
					<th class='stats-cell'>BLK</th>
					<th class='stats-cell'>TO</th>
                  </tr>
                </thead>
                <tbody>
                <?php
            		foreach ($players as $player)
            		{
						echo "<tr>";
	                  	echo "\n\t<td class='rank-font'>".$player['rnk_yhoo']."</td>";
						echo "\n\t<td class='rank-font'>".$player['rnk_espn']."</td>";
						echo "\n\t<td class='rank-font'>".$player['rnk_razz']."</td>";
						echo "\n\t<td class='name-cell'>".$player['name'].
								" <small class='team-pos'>".$player['team'].
								" - ".$player['pos']."</small>".
								"</td>";
						echo "\n\t<td>".$player['gms']."</td>";
						echo "\n\t<td>".substr($player['min'], 0, strlen($player['min']) - 1)."</td>";
						echo "\n\t<td>".substr($player['sea_fg'], 1)."</td>";
						echo "\n\t<td>".substr($player['sea_ft'], 1)."</td>";
						echo "\n\t<td>".$player['sea_3ptm']."</td>";
						echo "\n\t<td>".$player['sea_pts']."</td>";
						echo "\n\t<td>".$player['sea_reb']."</td>";
						echo "\n\t<td>".$player['sea_ast']."</td>";
						echo "\n\t<td>".$player['sea_stl']."</td>";
						echo "\n\t<td>".$player['sea_blk']."</td>";
						echo "\n\t<td>".$player['sea_to']."</td>";
						echo "\n</tr>\n";
					}

                ?>
                </tbody>
              </table>
              </div>

              <!-- Per Game -->
              <div class="tab-pane fade" id="pergame-tbl">
              <table class="table table-hover">
                <thead class="tbl-header">
                  <tr>
                  	<th class='rank-cell'>Y!</th>
					<th class='rank-cell'>E</th>
					<th class='rank-cell'>R</th>
					<th class='name-cell'>NAME</th>
					<th class='stats-cell'>FG%</th>
					<th class='stats-cell'>FT%</th>
					<th class='stats-cell'>3PM</th>
					<th class='stats-cell'>PTS</th>
					<th class='stats-cell'>REB</th>
					<th class='stats-cell'>AST</th>
					<th class='stats-cell'>STL</th>
					<th class='stats-cell'>BLK</th>
					<th class='stats-cell'>TO</th>
                  </tr>
                </thead>
                <tbody>
                <?php
            		foreach ($players as $player)
            		{
						echo "<tr>";
	                  	echo "\n\t<td class='rank-font'>".$player['rnk_yhoo']."</td>";
						echo "\n\t<td class='rank-font'>".$player['rnk_espn']."</td>";
						echo "\n\t<td class='rank-font'>".$player['rnk_razz']."</td>";
						echo "\n\t<td class='name-cell'>".$player['name'].
								" <small class='team-pos'>".$player['team'].
								" - ".$player['pos']."</small>".
								"</td>";
						echo "\n\t<td>".substr($player['prj_fg'], 1)."</td>";
						echo "\n\t<td>".substr($player['prj_ft'], 1)."</td>";
						echo "\n\t<td>".$player['prj_3ptm']."</td>";
						echo "\n\t<td>".$player['prj_pts']."</td>";
						echo "\n\t<td>".$player['prj_reb']."</td>";
						echo "\n\t<td>".$player['prj_ast']."</td>";
						echo "\n\t<td>".$player['prj_stl']."</td>";
						echo "\n\t<td>".$player['prj_blk']."</td>";
						echo "\n\t<td>".$player['prj_to']."</td>";
						echo "\n</tr>\n";
					}

                ?>
                </tbody>
              </table>
              </div>


              <!-- Projections -->
              <div class="tab-pane fade" id="projections-tbl">
              <table class="table table-hover">
                <thead class="tbl-header">
                  <tr>
                    <th>RNK</th>
                    <th>Y!</th>
                    <th>PLAYER</th>
                    <th>GMS</th>
                    <th>FG%</th>
                    <th>FT%</th>
                    <th>3PTM</th>
                    <th>PTS</th>
                    <th>REB</th>
                    <th>AST</th>
                    <th>ST</th>
                    <th>BLK</th>
                    <th>TO</th>
                  </tr>
                </thead>
                <tbody>
                  <tr>
                    <td>180</td>
                    <td>134</td>
                    <td>Kentavious Caldwell-Pope <small class="team-pos">DET - SG,SF</small></td>
                    <td>82</td>
                    <td>.434</td>
                    <td>.809</td>
                    <td>160</td>
                    <td>2209</td>
                    <td>600</td>
                    <td>500</td>
                    <td>180</td>
                    <td>120</td>
                    <td>240</td>
                  </tr>
                  <tr>
                    <td>180</td>
                    <td>134</td>
                    <td>Kentavious Caldwell-Pope</td>
                    <td>82</td>
                    <td>.434</td>
                    <td>.809</td>
                    <td>160</td>
                    <td>2209</td>
                    <td>600</td>
                    <td>500</td>
                    <td>180</td>
                    <td>120</td>
                    <td>240</td>
                  </tr>
                </tbody>
              </table>
              </div>


              <!-- Cat Analysis -->
              <div class="tab-pane fade" id="cat-tbl">
              <table class="table table-hover">
                <thead class="tbl-header">
                  <tr>
                    <th>RNK</th>
                    <th>Y!</th>
                    <th>PLAYER</th>
                    <th>GMS</th>
                    <th>FG%</th>
                    <th>FT%</th>
                    <th>3PTM</th>
                    <th>PTS</th>
                    <th>REB</th>
                    <th>AST</th>
                    <th>ST</th>
                    <th>BLK</th>
                    <th>TO</th>
                  </tr>
                </thead>
                <tbody>
                  <tr>
                    <td>180</td>
                    <td>134</td>
                    <td>Kentavious Caldwell-Pope <small class="team-pos">DET - SG,SF</small></td>
                    <td><span class="glyphicon glyphicon-ok"></span></td>
                    <td><span class="glyphicon glyphicon-ok"></span></td>
                    <td><span class="glyphicon glyphicon-ok"></span></td>
                    <td><span class="glyphicon glyphicon-minus"></span></td>
                    <td><span class="glyphicon glyphicon-ok"></span></td>
                    <td><span class="glyphicon glyphicon-remove"></span></td>
                    <td><span class="glyphicon glyphicon-ok"></span></td>
                    <td><span class="glyphicon glyphicon-minus"></span></td>
                    <td><span class="glyphicon glyphicon-remove"></span></td>
                    <td><span class="glyphicon glyphicon-ok"></span></td>
                  </tr>
                </tbody>
              </table>
              </div>
              </div> <!-- .tab-content -->
            </div>
          </div>

          <div class="col-lg-2 col-lg-offset-1">
            <div class="row well">
              <h6>My Team</h6>
            </div>
            <div class="row well">
              <h6>Draft Results</h6>
            </div>
            <div class="row well">
              <div class="form-group">
                <textarea class="form-control" rows="3" id="textArea" placeholder="Paste draft results here"></textarea>
                <br>
                <a href="#" class="btn btn-danger btn-sm">Update</a>
              </div>
            </div>

          </div>
        </div>
      </div>
    </div><!-- /.container -->